<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>
<body>
    <a href="16.history对象2.html">16.history对象2.html</a>
    <button>跳转</button>

    <script>
        const btnObj = document.querySelector("button")
        btnObj.addEventListener("click",function(){
            //前进
            // window.history.forward();  //是在历史记录里前进后退
            history.go(1)           //和上面是一样的
        })
    </script>
</body>
</html>